import Vue from 'vue'
import Router from 'vue-router'
import HelloWorld from '@/components/HelloWorld'
import Demo from '@/components/Demo'
import Demo2 from '@/components/Demo2'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'HelloWorld',
      component: HelloWorld,
      children:[
        {path: '/demo',
          name: 'Demo',
          component: Demo,},
        {path: '/demo2',
          name: 'Demo2',
          component: Demo2,}
      ]
    }
  ]
})
